<!DOCTYPE html>
<title>Canvas test: security.pattern.create</title>
<script src="../tests.js"></script>
<link rel="stylesheet" href="../tests.css">
<link rel="prev" href="security.drawImage.canvas.html" title="security.drawImage.canvas">
<link rel="next" href="security.pattern.cross.html" title="security.pattern.cross">
<body class="show_output">
<p>
 <a href="security.drawImage.canvas.html" accesskey="p" title="[p] security.drawImage.canvas">&lt;</a>
 <a href="index.html">[index]</a>
 <a href="security.pattern.cross.html" accesskey="n" title="[n] security.pattern.cross">&gt;</a>
<h1><a href="index.security.html">security</a>.<a href="index.security.pattern.html">pattern</a>.create</h1>
<p class="desc">Creating an unclean pattern does not make the canvas origin-unclean</p>
<div class="refs">References:
<ul>
<li><a href="spec.html#testrefs.security.start">security.start</a>

</ul>
</div>

<p class="output">Actual output:</p>
<canvas id="c" class="output" width="100" height="50"><p class="fallback">FAIL (fallback content)</p></canvas>

<ul id="d"></ul>
<script>
_addTest(function(canvas, ctx) {

var p = ctx.createPattern(document.getElementById('yellow.png'), 'repeat');
canvas.toDataURL();
ctx.getImageData(0, 0, 1, 1);
_assert(true, "true"); // okay if there was no exception


});
</script>
<img src="http://localhost:8000/canvas/philip/images/yellow.png" id="yellow.png" class="resource">

